package com.ibuonline.b2b.entity;

import java.io.Serializable;

public class BaseCountry implements Serializable {

	private static final long serialVersionUID = 1360581723649156578L;

	//fields
	private java.lang.Integer id;
	private java.lang.String cname;
	private java.lang.String ename;
	private java.lang.String code;
	private java.lang.String phone;
	private java.lang.Double timeLag;

	//default constructor
	public BaseCountry() {
	}

	//getter
	public java.lang.Integer getId() {
		return id;
	}
	public java.lang.String getCname() {
		return cname;
	}
	public java.lang.String getEname() {
		return ename;
	}
	public java.lang.String getCode() {
		return code;
	}
	public java.lang.String getPhone() {
		return phone;
	}
	public java.lang.Double getTimeLag() {
		return timeLag;
	}

	//setter
	public void setId(java.lang.Integer id) {
		this.id = id;
	}
	public void setCname(java.lang.String cname) {
		this.cname = cname;
	}
	public void setEname(java.lang.String ename) {
		this.ename = ename;
	}
	public void setCode(java.lang.String code) {
		this.code = code;
	}
	public void setPhone(java.lang.String phone) {
		this.phone = phone;
	}
	public void setTimeLag(java.lang.Double timeLag) {
		this.timeLag = timeLag;
	}

	//equals method
	public boolean equals(Object other) {
		if (this == other)
			return true;
		if (!(other instanceof BaseCountry))
			return false;

		final BaseCountry baseCountry = (BaseCountry)other;
		if (!this.id.equals(baseCountry.getId()))
			return false;

		return true;
	}

	//hashCode method
	public int hashCode() {
		StringBuffer keys = new StringBuffer();
		keys.append(id).append(",");
		if (keys.length() > 0)
			keys.deleteCharAt(keys.length() - 1);
		return keys.toString().hashCode();
	}

	//toString method
	public String toString() {
		return new StringBuilder("BaseCountry[")
			.append("id=").append(id).append(", ")
			.append("cname=").append(cname).append(", ")
			.append("ename=").append(ename).append(", ")
			.append("code=").append(code).append(", ")
			.append("phone=").append(phone).append(", ")
			.append("timeLag=").append(timeLag).append("]").toString();
	}
}